Skip to content

[SFW Switch] Audio handling + Additional plugin support#679

Open
Servbot91 wants to merge 14 commits intostashapp:mainfrom
Servbot91:feature/mute-sound
Open

[SFW Switch] Audio handling + Additional plugin support#679
Servbot91 wants to merge 14 commits intostashapp:mainfrom
Servbot91:feature/mute-sound

Conversation

@Servbot91
Copy link
Contributor

@Servbot91 Servbot91 commented Mar 7, 2026

New Feature:

  • SFW Switch when enabled will mute all sound sources by default.
  • You can enable sound manually using audio buttons.
  • Switching scenes will resume mute.
  • Clicking later in a scene timeline on the same page will force the mute again. This is to protect against accidental clicks or volume discrepancies.
  • Sound implementation should include all additional plugins going forward without additional refactoring.

Additional Plugin Support:

  • Added support for the Sprite Tab plugin
  • Each sprite is blurred individually

Testing:

  • All functionality verified and tested in dev. No issues.

Servbot91 and others added 3 commits March 4, 2026 13:27
Clarified instructions for adding custom selectors to additional_plugins.css.
@discourse-stashapp
Copy link

This pull request has been mentioned on Stash Forum. There might be relevant details there:

https://discourse.stashapp.cc/t/sfw-switch/4658/16

@DogmaDragon DogmaDragon added the type:plugin Plugins label Mar 15, 2026
@DogmaDragon DogmaDragon changed the title Feature: Audio handling + Additional plugin support [SFW Switch] Audio handling + Additional plugin support Mar 15, 2026
@DogmaDragon
Copy link
Contributor

I think the audio muting should be optional (off by default) and handled via plugin settings. It's likely to cause confusion for someone when they install the plugin and get no audio than if they enable it themselves because they need that additional feature.

@Servbot91
Copy link
Contributor Author

@DogmaDragon It is optional now. When boolean is false (default) only thumbnails are blurred. When boolean setting is true, audio sources get hard muted.

@DogmaDragon
Copy link
Contributor

From my testing the blur is not applied universally. I'm not sure if everywhere should have it, but the inconsitancy is noticable.

Scenes (grid view)

  • Date is not blurred
  • Studio is not blurred

Scenes (list view)

  • No blur

Scenes (wall view)

  • No blur

Scenes (tagger view)

  • Only scene cover blurred

Images (grid view)

  • Studio is not blurred

Images (list view)

  • No blur

Groups

  • Date is not blurred
  • Synopsis is not blurred

Markers (grid view)

  • Marker screenshot is not blurred
  • Time is not blurred
  • End time is not blurred
  • Marker label is not blurred

Markers (wall view)

  • No blur

Galleries (grid view)

  • Studio is not blurred

Galleries (list view)

  • No blur

Galleries (wall view)

  • No blur

Performers (grid view)

  • Age is not blurred

Performers (list view)

  • No blue

Performers (tagger view)

  • Only performer cover blurred

Studios (grid view)

  • "Parent of" text is not blurred

Studios (tagger view)

  • Only studio cover is blurred

Tags (grid view)

  • "Parent of" text is not blurred
  • "Sub-tag of" text is not blurred

Tags (list view)

  • No blur

Tags (tagger view) (I think it's still a develop feature)

  • Only tag cover is blurred

Stats

  • Is it mean to blur the basic stats?

@DogmaDragon
Copy link
Contributor

DogmaDragon commented Mar 17, 2026

There is a bug with audio and blur toggle.

If you disable blur toggle mid-scene the audio with play in infinity even if you stop the scene. Only leaving the page or re-enabling the blur toggle will stop the loop.

Also, audio is not unmuted when the blur toggle is disabled.

Comment on lines +11 to +12
position: relative;
display: inline-block;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the reason behind this change?

.image-container img,
.detail-header-image,
.scene-player-container {
display: block;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the reason behind this change?

@Servbot91
Copy link
Contributor Author

@DogmaDragon Hey man, thanks for the test. Full disclosure, alot of what you asked for was not blurred in the original plugin. I have added most if not all of your request including the lightbox. I also fixed the zombie audio issue, I didnt blur things that are not inherently NSFW like dates, but I did do age and other stuff that makes sense. Un-blurred stash box stats. I also aggregated some of the original CSS back into this version, however alot of it was very loosely targeted so you would get unintended affects elsewhere.

Either way, its pretty solid now.

The only feature I did not add was the tagger view as I dont use that feature and not sure how I can go about that without having to connect to stash box.

@discourse-stashapp
Copy link

This pull request has been mentioned on Stash Forum. There might be relevant details there:

https://discourse.stashapp.cc/t/sfw-switch/4658/20

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are we removing this?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thats my bad I forgot it in the commit. Its here in latest commit.

@DogmaDragon
Copy link
Contributor

Groups page seelctor is too strict. It blurs the whole cards.

image

@DogmaDragon
Copy link
Contributor

Scene wall view is not blurring the cover image.

@DogmaDragon
Copy link
Contributor

Image wall view is too strict. Blurs the whole block instead of individual thumbnails.

@DogmaDragon
Copy link
Contributor

Markers wall view is too strict. Blurs the whole block instead of individual marker covers.

@DogmaDragon
Copy link
Contributor

Gallery wall view is not blurred.

@Servbot91
Copy link
Contributor Author

Servbot91 commented Mar 17, 2026 via email

@Servbot91
Copy link
Contributor Author

Servbot91 commented Mar 17, 2026 via email

@DogmaDragon
Copy link
Contributor

.wall-item img {
    filter: blur(30px);
    transition: filter 0.25s ease;
  }
.wall-item img:hover {
   filter: blur(0px);
   transition: filter 0.25s ease;
}

Works for me.

@Servbot91
Copy link
Contributor Author

Scene wall view is not blurring the cover image.

.wall-item img {
    filter: blur(30px);
    transition: filter 0.25s ease;
  }
.wall-item img:hover {
   filter: blur(0px);
   transition: filter 0.25s ease;
}

Works for me.

for what? I have added scene wall but what is this for? I dont see what this is targeted at.

@DogmaDragon
Copy link
Contributor

You can tighten the selector to specific pages, but it works on both images and markers wall views.

@DogmaDragon
Copy link
Contributor

@Servbot91 I think I unfairly added more work on you since as you mentioned many of these inconsistancies were present already.

If you split just the audio changes and sprite plugin support into a new PR I can merge that. And then we can work on the missing options later.

@Servbot91
Copy link
Contributor Author

@Servbot91 I think I unfairly added more work on you since as you mentioned many of these inconsistancies were present already.

If you split just the audio changes and sprite plugin support into a new PR I can merge that. And then we can work on the missing options later.

All good I think I got everything you asked in this last push. Should be pretty solid now, but yeah none of this was in the original.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants